package com.hcb.tonguetiphealth.model;

import java.text.SimpleDateFormat;




public class HealthCateComment extends AbstractTask {
	/**
	 * 
	 */
	private static final long serialVersionUID = 1L;
	private String id;
	private float level;        //评级
	private long addTime;
	
	private User user;         //评论用户
	
	public String getId() {
		return formate(id);
	}
	public void setId(String id) {
		this.id = id;
	}
	public float getLevel() {
		return level;
	}
	public void setLevel(float level) {
		this.level = level;
	}
	public User getUser() {
		if(user == null) {
			user = new User();
		}
		return user;
	}
	public void setUser(User user) {
		this.user = user;
	}
	public long getAddTime() {
		return addTime;
	}
	public String getDate() {
		if(addTime > 0) {
			SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");
			return sdf .format(addTime * 1000);
		} else {
			return "";
		}
	}
	public void setAddTime(long addTime) {
		this.addTime = addTime;
	}

}
